package com.scu.baseline.mapper;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;
import com.scu.baseline.pojo.Department;

/**
 * (Department)表数据库访问层
 *
 * @author AlonBurukeses
 * @since 2022-06-23 09:14:21
 */
public interface Departmentmapper  {

/**
* 批量新增数据（MyBatis原生foreach方法）
*
* @param entities List<Department> 实例对象列表
* @return 影响行数
*/
int insertBatch(@Param("entities") List<Department> entities);

/**
* 批量新增或按主键更新数据（MyBatis原生foreach方法）
*
* @param entities List<Department> 实例对象列表
* @return 影响行数
* @throws org.springframework.jdbc.BadSqlGrammarException 入参是空List的时候会抛SQL语句错误的异常，请自行校验入参
*/
int insertOrUpdateBatch(@Param("entities") List<Department> entities);
List<Department> selectall();
List<Department> selectByPage(Integer index);
List<Department> selectByName(String departmentName);
void insertbymap(Map map);
void updatebymap(Map map);
void deleteById(Integer departmentId);
Integer count();
}

